#include <vector>
#include <iostream>
#include <algorithm>
#include <cmath>
using namespace std;
int a[100005]={0};
bool cmp(int a,int b){
	return a > b;
}
void solve(int* a, int i, int w)
{
	int line = floor((i +1)* w/100);
	sort(a,a+i,cmp);
	cout << a[line-1] << " ";
}
int main()
{
	// 请在此输入您的代码
	int n, w;
	cin >> n >> w;
//	vector<int> a;
	cin >> a[0];
	cout << a[0] <<" ";
	for (int i = 1; i < n ; i ++) {
		cin >> a[i];
		solve(a, i, w);
	}

	return 0;
}
